package com.itheima.stock.mapper;

import com.itheima.stock.entity.StockMarketIndexInfo;
import com.itheima.stock.entity.StockMarketLogPrice;
import org.apache.ibatis.annotations.MapKey;
import org.apache.ibatis.annotations.Param;

import java.time.LocalDate;
import java.time.LocalDateTime;
import java.util.Date;
import java.util.List;
import java.util.Map;

/**
* @author fantuan
* @description 针对表【stock_market_index_info(股票大盘数据详情表)】的数据库操作Mapper
* @createDate 2025-11-07 20:42:37
* @Entity com.itheima.stock.entity.StockMarketIndexInfo
*/
public interface StockMarketIndexInfoMapper {
    List<StockMarketIndexInfo> selectByIdsAndDateTime(@Param("ids") List<String> ids,@Param("last") LocalDateTime last);

    @MapKey("key")
    List<Map> stockTradeVolCount(@Param("marketIds") List<String> inner,@Param("openDate") Date tOpenTime,@Param("stockDateTime") Date tDateTime);

    /**
     * 批量插入股票大盘数据
     * @param infos
     */
    int insertBatch(List<StockMarketIndexInfo> infos);
}




